package com.nlx.notes.module.service.gold;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.nlx.notes.module.bean.dto.gold.GoldSalePageQueryDTO;
import com.nlx.notes.module.bean.vo.flow.GoldSaleSumOverviewVO;
import com.nlx.notes.module.entity.GoldSaleRecordEntity;

import java.util.List;

public interface GoldSaleRecordService extends IService<GoldSaleRecordEntity> {

    /**
     * 查询用户售卖的总数
     * @param goldSalePageQueryDTO 参数
     * @return long
     */
    long countByCondition(GoldSalePageQueryDTO goldSalePageQueryDTO);

    /**
     * 查询售卖的列表数据
     * @param goldSalePageQueryDTO 参数
     * @return GoldSaleRecordEntity
     */
    IPage<GoldSaleRecordEntity> pageByCondition(GoldSalePageQueryDTO goldSalePageQueryDTO);

    /**
     * 获取总数相关数据
     * @param userId 用户id
     * @return GoldSaleSumOverviewVO
     */
    GoldSaleSumOverviewVO sumByUserId(Long userId);
}
